package utils.webdav;

import entity.ConfigFile;
import lombok.Getter;
import utils.json.InitConfig;

/**
 * WebDav配置类
 * UserName 用户名
 * PassWord 密码
 * BaseURL webdav根目录地址
 */
@Getter
public class WebDavConfig {
    private final String UserName;
    private final String PassWord;
    private final String BaseURL;
    private static final WebDavConfig instance = new WebDavConfig();
    ConfigFile config = InitConfig.getInstance().getConfig();

    private WebDavConfig() {
        this.UserName = config.getWebdav().getUserName();
        this.PassWord = config.getWebdav().getPassWord();
        this.BaseURL = config.getWebdav().getBaseURL();
    }

    public static WebDavConfig getInstance() {
        return instance;
    }
}
